babl.git
13 years agoreplace gamma functions with #defines
Øyvind Kolås [Sun, 22 Apr 2012 23:53:27 +0000 (01:53 +0200)]
replace gamma functions with #defines

Causes some slight speedup across babl on less agressive optimization
levels.

13 years agoallocate temporary buffers for fish conversion on the stack
Øyvind Kolås [Sun, 22 Apr 2012 23:07:14 +0000 (01:07 +0200)]
allocate temporary buffers for fish conversion on the stack

This avoids calling malloc/free for fishes that consists of multiple steps.

13 years agobase: added IEEE 754-2008 half precision float
Øyvind Kolås [Sat, 21 Apr 2012 23:31:05 +0000 (01:31 +0200)]
base: added IEEE 754-2008 half precision float

Using BSD licensed code that means applications using babl should display the
appropriate copyright header - or this code needs to be reimplemented so that
babl can retain the functionality without that additional requirement.

13 years agotests: added test to extract a component
Øyvind Kolås [Tue, 10 Apr 2012 22:05:28 +0000 (00:05 +0200)]
tests: added test to extract a component

13 years agogobject-introspection: fix build of the .gir and .typelib files.
Dominique Leuenberger [Tue, 10 Jan 2012 16:32:50 +0000 (17:32 +0100)]
gobject-introspection: fix build of the .gir and .typelib files.

13 years agobabl/babl-palette.c: remove include of <values.h>
Øyvind Kolås [Thu, 5 Apr 2012 14:39:15 +0000 (16:39 +0200)]
babl/babl-palette.c: remove include of <values.h>

No longer needed when limits.h is included.

13 years agobabl/babl-palette.c: #include <limits.h>
Øyvind Kolås [Thu, 5 Apr 2012 14:35:51 +0000 (16:35 +0200)]
babl/babl-palette.c: #include <limits.h>

Fixing bug #673466 from reported by Tim Mooney, makes babl build on solaris.

13 years agopost release bump version to 0.1.11
Øyvind Kolås [Mon, 2 Apr 2012 21:37:01 +0000 (22:37 +0100)]
post release bump version to 0.1.11

13 years agorelease 0.1.10
Øyvind Kolås [Mon, 2 Apr 2012 21:35:06 +0000 (22:35 +0100)]
release 0.1.10

13 years agoGet rid of ChangeLog
Øyvind Kolås [Mon, 2 Apr 2012 21:25:22 +0000 (22:25 +0100)]
Get rid of ChangeLog

Only sentimental reasons to keep it around.

13 years agoextensions: quadruple precision of LUT based floatfuncs
Øyvind Kolås [Sun, 1 Apr 2012 18:41:47 +0000 (19:41 +0100)]
extensions: quadruple precision of LUT based floatfuncs

(without increasing the size of the lookup tables, with neglible
performance cost)

13 years agofast-float: reduce overhead of saturating LUT
Øyvind Kolås [Sun, 1 Apr 2012 14:08:13 +0000 (15:08 +0100)]
fast-float: reduce overhead of saturating LUT

13 years agoextensions/fast-float: reduce precision
Øyvind Kolås [Sun, 1 Apr 2012 14:03:10 +0000 (15:03 +0100)]
extensions/fast-float: reduce precision

Reduce sizes of lookup tables by an order of magnitude, doubling the run-time
performance.

13 years agoextensions: add lut based gamma for float
Øyvind Kolås [Sun, 1 Apr 2012 02:08:53 +0000 (03:08 +0100)]
extensions: add lut based gamma for float

13 years agobabl: reduce number of pixels tested when profiling to 128
Øyvind Kolås [Sat, 31 Mar 2012 16:08:16 +0000 (17:08 +0100)]
babl: reduce number of pixels tested when profiling to 128

13 years agoextensions: get rid of some of the conversions with the highest errors
Øyvind Kolås [Sat, 31 Mar 2012 14:34:31 +0000 (15:34 +0100)]
extensions: get rid of some of the conversions with the highest errors

13 years agoextensions: remove optmized powf, use the fully correct optimization from base
Øyvind Kolås [Sat, 31 Mar 2012 14:06:52 +0000 (15:06 +0100)]
extensions: remove optmized powf, use the fully correct optimization from base

13 years agoextensions: add an extension with some float optimizations
Øyvind Kolås [Sat, 31 Mar 2012 13:58:49 +0000 (14:58 +0100)]
extensions: add an extension with some float optimizations

Alos improve some alpha unpremultiplications in other extensions.

13 years agobase/util.h change define used in include guards
Øyvind Kolås [Sat, 31 Mar 2012 13:58:16 +0000 (14:58 +0100)]
base/util.h change define used in include guards

13 years agouse optimized powf for x^(1.0/2.4)
Øyvind Kolås [Sat, 31 Mar 2012 02:47:06 +0000 (03:47 +0100)]
use optimized powf for x^(1.0/2.4)

13 years agoreorder loops of reference premul
Øyvind Kolås [Sat, 31 Mar 2012 02:44:45 +0000 (03:44 +0100)]
reorder loops of reference premul

13 years agouse sse conversions also for gamma corrected data
Øyvind Kolås [Sat, 31 Mar 2012 01:50:43 +0000 (02:50 +0100)]
use sse conversions also for gamma corrected data

13 years agopost release version bump to 0.1.9
Øyvind Kolås [Thu, 29 Mar 2012 23:37:00 +0000 (00:37 +0100)]
post release version bump to 0.1.9

13 years agobump version to 0.1.8
Øyvind Kolås [Thu, 29 Mar 2012 23:33:09 +0000 (00:33 +0100)]
bump version to 0.1.8

Also updated NEWS

13 years agobuild: do not enable introspection even for distcheck
Øyvind Kolås [Thu, 29 Mar 2012 23:31:43 +0000 (00:31 +0100)]
build: do not enable introspection even for distcheck

13 years agopalette: return the same values if same name is provided
Øyvind Kolås [Thu, 29 Mar 2012 23:14:49 +0000 (00:14 +0100)]
palette: return the same values if same name is provided

13 years agopalette: change alpha reporting for palette formats
Øyvind Kolås [Wed, 28 Mar 2012 19:28:48 +0000 (20:28 +0100)]
palette: change alpha reporting for palette formats

Only return TRUE if the format has a dedicated alpha component.

13 years agopalette: use INT_MAX instead of MAXINT
Øyvind Kolås [Mon, 26 Mar 2012 14:29:12 +0000 (15:29 +0100)]
palette: use INT_MAX instead of MAXINT

13 years agoadd babl_format_is_palette
Øyvind Kolås [Wed, 21 Mar 2012 18:13:38 +0000 (18:13 +0000)]
add babl_format_is_palette

13 years agopalette: return the BablModel created
Øyvind Kolås [Mon, 19 Mar 2012 15:24:36 +0000 (15:24 +0000)]
palette: return the BablModel created

13 years agodisable gobject introspection by default
Øyvind Kolås [Mon, 19 Mar 2012 12:46:45 +0000 (12:46 +0000)]
disable gobject introspection by default

The tooling crashes with odd strlen assertions breaking the build on many
existing linux distros. This change should make gobject introspection
disabled by defualt.

13 years agopalette: optimize rgb(a) -> palette index computation
Øyvind Kolås [Mon, 19 Mar 2012 02:55:32 +0000 (02:55 +0000)]
palette: optimize rgb(a) -> palette index computation

13 years agopalette: add fast paths for adding and removing alpha channel
Øyvind Kolås [Sun, 18 Mar 2012 22:10:20 +0000 (22:10 +0000)]
palette: add fast paths for adding and removing alpha channel

13 years agotests: constify tests
Øyvind Kolås [Sun, 18 Mar 2012 16:57:04 +0000 (16:57 +0000)]
tests: constify tests

13 years agoconstify API
Øyvind Kolås [Sun, 18 Mar 2012 15:58:11 +0000 (15:58 +0000)]
constify API

13 years agopalette: add fastish path for alpha<->no alpha
Øyvind Kolås [Sun, 18 Mar 2012 15:00:07 +0000 (15:00 +0000)]
palette: add fastish path for alpha<->no alpha

13 years agocarry around user data in BablConversion
Øyvind Kolås [Sun, 18 Mar 2012 14:17:04 +0000 (14:17 +0000)]
carry around user data in BablConversion

Having the user data for relevant conversions directly in BablConversion
permits avoiding branches in the dispatch code. Branches in dispatch code
is evil, thus desinging the rest around avoiding that.

13 years agopalette: changed API to have aplha and non-alpha formats in out arguments
Øyvind Kolås [Sun, 18 Mar 2012 13:10:19 +0000 (13:10 +0000)]
palette: changed API to have aplha and non-alpha formats in out arguments

13 years agomake babl pass valgrinding
Øyvind Kolås [Sun, 18 Mar 2012 11:39:12 +0000 (11:39 +0000)]
make babl pass valgrinding

13 years agopalette: initialize with 8bit fast path buffer
Øyvind Kolås [Sun, 18 Mar 2012 02:52:00 +0000 (02:52 +0000)]
palette: initialize with 8bit fast path buffer

13 years agoadd 8bit fast path for pal -> rgba
Øyvind Kolås [Sun, 18 Mar 2012 00:10:52 +0000 (00:10 +0000)]
add 8bit fast path for pal -> rgba

13 years agoadd bablformats that match the hosts endianness
Øyvind Kolås [Sat, 17 Mar 2012 23:54:49 +0000 (23:54 +0000)]
add bablformats that match the hosts endianness

13 years agopalette: cache the double version of the palette internally
Øyvind Kolås [Sat, 17 Mar 2012 19:39:21 +0000 (19:39 +0000)]
palette: cache the double version of the palette internally

13 years agopalette: add capability to use palette formats with separate alpha
Øyvind Kolås [Sat, 17 Mar 2012 17:02:44 +0000 (17:02 +0000)]
palette: add capability to use palette formats with separate alpha

Also refactored to make babl-palette.c only use public API.

13 years agoadd file missing from last commit
Øyvind Kolås [Sat, 17 Mar 2012 12:32:47 +0000 (12:32 +0000)]
add file missing from last commit

13 years agoadd API for managing palette based formats
Øyvind Kolås [Sat, 17 Mar 2012 12:22:10 +0000 (12:22 +0000)]
add API for managing palette based formats

13 years agobabl: add ability to register user data with BablModel
Øyvind Kolås [Sat, 17 Mar 2012 12:18:54 +0000 (12:18 +0000)]
babl: add ability to register user data with BablModel

The user data is available in the callback functions, no ABI change only
processing functions interested in this data needs to define the arguments,..
keeping ABI compatibility.

13 years agotests: add missing test
Øyvind Kolås [Fri, 16 Mar 2012 11:53:45 +0000 (11:53 +0000)]
tests: add missing test

13 years agoadd ability to extract component with 1 component formats
Øyvind Kolås [Fri, 16 Mar 2012 11:25:59 +0000 (11:25 +0000)]
add ability to extract component with 1 component formats

13 years agoconstify source argument of babl_process
Øyvind Kolås [Thu, 15 Mar 2012 22:11:56 +0000 (22:11 +0000)]
constify source argument of babl_process

14 years agobase: remove unused model-cmyk
Øyvind Kolås [Fri, 23 Dec 2011 11:44:14 +0000 (11:44 +0000)]
base: remove unused model-cmyk

14 years agopost release version bump to 0.1.7
Øyvind Kolås [Fri, 18 Nov 2011 18:47:02 +0000 (18:47 +0000)]
post release version bump to 0.1.7

14 years agobump version to 0.1.6
Øyvind Kolås [Fri, 18 Nov 2011 18:44:58 +0000 (18:44 +0000)]
bump version to 0.1.6

14 years agobuild: clean generated vapi file
Nils Philippsen [Fri, 18 Nov 2011 16:36:04 +0000 (17:36 +0100)]
build: clean generated vapi file

14 years agobuild: bump automake requirement to 1.11
Øyvind Kolås [Mon, 17 Oct 2011 17:07:19 +0000 (18:07 +0100)]
build: bump automake requirement to 1.11

This is needed for the silent build rules, and probably more.

14 years agoCopy introspection.m4 on tree
Javier Jardón [Mon, 17 Oct 2011 16:04:38 +0000 (17:04 +0100)]
Copy introspection.m4 on tree

This avoid us to depend on a system installed gobject-introspection
package.

14 years agobuild: Set automake options in AM_INIT_AUTOMAKE
Javier Jardón [Mon, 17 Oct 2011 12:36:42 +0000 (13:36 +0100)]
build: Set automake options in AM_INIT_AUTOMAKE

14 years agoMakefile.am: Remove m4/introspection.m4 from EXTRA_DIST
Javier Jardón [Mon, 17 Oct 2011 12:35:11 +0000 (13:35 +0100)]
Makefile.am: Remove m4/introspection.m4 from EXTRA_DIST

14 years agobuild: Do not use local copy of introspection.m4
Javier Jardón [Mon, 17 Oct 2011 12:21:53 +0000 (13:21 +0100)]
build: Do not use local copy of introspection.m4

14 years agoautogen.sh: Use autoreconf instead custom script
Javier Jardón [Mon, 17 Oct 2011 02:00:44 +0000 (03:00 +0100)]
autogen.sh: Use autoreconf instead custom script

14 years agoconfigure.ac: Replace deprecated AC_STDC_HEADERS macro
Javier Jardón [Mon, 17 Oct 2011 01:56:07 +0000 (02:56 +0100)]
configure.ac: Replace deprecated AC_STDC_HEADERS macro

14 years agoconfigure.ac: Use new libtool syntax
Javier Jardón [Mon, 17 Oct 2011 01:55:08 +0000 (02:55 +0100)]
configure.ac: Use new libtool syntax

14 years agoconfigure.ac: Check for AM_SILENT_RULES after AM_INIT_AUTOMAKE
Javier Jardón [Mon, 17 Oct 2011 01:52:51 +0000 (02:52 +0100)]
configure.ac: Check for AM_SILENT_RULES after AM_INIT_AUTOMAKE

14 years agoconfigure.ac: PACKAGE_NAME is already defined by AC_INIT
Javier Jardón [Mon, 17 Oct 2011 01:50:10 +0000 (02:50 +0100)]
configure.ac: PACKAGE_NAME is already defined by AC_INIT

14 years agoconfigure.ac: Replace AM_CONFIG_HEADER deprecated macro
Javier Jardón [Mon, 17 Oct 2011 01:48:47 +0000 (02:48 +0100)]
configure.ac: Replace AM_CONFIG_HEADER deprecated macro

Use AC_CONFIG_HEADERS instead

14 years agoMakefile.am: honor aclocal flags
Javier Jardón [Mon, 17 Oct 2011 01:47:21 +0000 (02:47 +0100)]
Makefile.am: honor aclocal flags

14 years agobuild: Remove --enable-maintainer-mode as it's now the default
Mukund Sivaraman [Mon, 12 Sep 2011 19:22:06 +0000 (00:52 +0530)]
build: Remove --enable-maintainer-mode as it's now the default

14 years agobuild: Don't complain about non-GNU make rules
Mukund Sivaraman [Mon, 12 Sep 2011 19:20:21 +0000 (00:50 +0530)]
build: Don't complain about non-GNU make rules

14 years agobuild: Enable maintainer mode by default
Mukund Sivaraman [Mon, 12 Sep 2011 19:08:29 +0000 (00:38 +0530)]
build: Enable maintainer mode by default

See <http://blogs.gnome.org/desrt/2011/09/08/am_maintainer_mode-is-not-cool/>.

14 years agoadd the possibility to distinct format_n type from the others
Michael Muré [Fri, 19 Aug 2011 20:32:07 +0000 (22:32 +0200)]
add the possibility to distinct format_n type from the others

14 years agoFix install of babl vapi file
Jon Nordby [Wed, 3 Aug 2011 22:45:04 +0000 (00:45 +0200)]
Fix install of babl vapi file

The pkg-config package refered no longer exists,
and currently only libvala provides a vapidir in pkg-config,
and this package is versioned and changes all the time.
Other projects just use $(datadir)/vala/vapi, so we do the same

14 years agoBuild Vala support (.vapi file) by default
Jon Nordby [Wed, 3 Aug 2011 21:13:29 +0000 (23:13 +0200)]
Build Vala support (.vapi file) by default

Generated from .gir file.

14 years agoRemove trailing space in comments
Barak Itkin [Thu, 21 Jul 2011 14:33:17 +0000 (17:33 +0300)]
Remove trailing space in comments

14 years agomask out unwanted formats with if(0) {...}
Nils Philippsen [Thu, 26 May 2011 20:50:57 +0000 (22:50 +0200)]
mask out unwanted formats with if(0) {...}

premature return statements make source code checkers unhappy

14 years agoget rid of hack_hack(), use NEEDS_BABL_DB instead
Nils Philippsen [Thu, 26 May 2011 14:04:54 +0000 (16:04 +0200)]
get rid of hack_hack(), use NEEDS_BABL_DB instead

14 years agocatch babl_{format,model}_new calls with missing parameters
Nils Philippsen [Thu, 26 May 2011 13:37:09 +0000 (15:37 +0200)]
catch babl_{format,model}_new calls with missing parameters

14 years agoadd comment about case falling through
Nils Philippsen [Thu, 26 May 2011 10:34:14 +0000 (12:34 +0200)]
add comment about case falling through

this makes code checker tools happy and the code easier to understand

14 years agofix element size when allocating chain_table
Nils Philippsen [Thu, 26 May 2011 10:22:23 +0000 (12:22 +0200)]
fix element size when allocating chain_table

14 years agoDo not reject colliding conversion names
Øyvind Kolås [Thu, 21 Apr 2011 11:00:31 +0000 (12:00 +0100)]
Do not reject colliding conversion names

Permit registering multiple conversions between the same formats from the same
extension. Babl was rejecting subsequent conversions/variations in the same
module; this is desired for most other types of babl objects but not
conversions.

14 years agobase: don't define and set unused variable
Nils Philippsen [Wed, 20 Apr 2011 11:43:08 +0000 (13:43 +0200)]
base: don't define and set unused variable

otherwise gcc 4.6 would warn about it

14 years agostats: change percentage of pixels needed to be part of negative stats
Øyvind Kolås [Sun, 17 Apr 2011 16:58:52 +0000 (17:58 +0100)]
stats: change percentage of pixels needed to be part of negative stats

14 years agoextensions: Remove some of the blatantly wrong conversions
Øyvind Kolås [Sun, 17 Apr 2011 16:50:11 +0000 (17:50 +0100)]
extensions: Remove some of the blatantly wrong conversions

These conversions would never be chosen anyways, even with high tolerance, but
they are dead code and can just be removed.

14 years agostats: remove false negatives from HTML stats output
Øyvind Kolås [Sun, 17 Apr 2011 16:22:12 +0000 (17:22 +0100)]
stats: remove false negatives from HTML stats output

too many of the conversions are flagged as bad in the matrix change code so
that only conversions that contribute to more than 0.1% of the overall pixels
converted by babl are shown in the stats written when BABL_STATS environment
variable is set.

14 years agodocs: fixed example code in index-static.html.in
Rupert Weber [Wed, 1 Sep 2010 16:16:10 +0000 (18:16 +0200)]
docs: fixed example code in index-static.html.in

added babl_init(), fish can't be const, Babl* can't be dereferenced,
one variable name changed during example, added sizeof to make it
a little more obvious.

14 years agodocs: HTML cleanup
Rupert Weber [Wed, 1 Sep 2010 15:54:21 +0000 (17:54 +0200)]
docs: HTML cleanup

Small HTML cleanups like missing end-tags so page passes
HTML validator.

14 years agobuild: Remove --pkg babl option to g-ir-scanner
Jon Nordby [Mon, 28 Mar 2011 20:16:11 +0000 (22:16 +0200)]
build: Remove --pkg babl option to g-ir-scanner

--pkg is intended for dependencies. Babl does not depend on Babl
This lead to g-ir-scanner barfing if Babl was not already installed.

15 years agofix building in separate directory
Nils Philippsen [Wed, 2 Mar 2011 10:42:37 +0000 (11:42 +0100)]
fix building in separate directory

15 years agopost release bump to 0.1.5
Øyvind Kolås [Thu, 20 Jan 2011 22:36:19 +0000 (22:36 +0000)]
post release bump to 0.1.5

15 years agobump version to 0.1.4
Øyvind Kolås [Thu, 20 Jan 2011 22:35:09 +0000 (22:35 +0000)]
bump version to 0.1.4

15 years agoremoved redundant RGBA double registration
Rupert Weber [Sun, 19 Sep 2010 12:59:07 +0000 (14:59 +0200)]
removed redundant RGBA double registration

"RGBA double2 was registred twice, once per name, once per id.

15 years agoallow reregistering but check for differences
Rupert Weber [Fri, 1 Oct 2010 00:18:53 +0000 (02:18 +0200)]
allow reregistering but check for differences

babl_model_new() emitted a warning when reregistering a model,
babl_format_new(), babl_type_new(), and babl_component_new()
quietly returned a preexisting object.

Changed so that all four functions return the preexisting object
if the new registration doesn't conflict, otherwise make the
error fatal.

(Fixed some conflicting and redundant registrations for
"Y'CbCr u8" along the way)

15 years agoFix make distcheck
Martin Nordholts [Wed, 29 Dec 2010 07:25:50 +0000 (08:25 +0100)]
Fix make distcheck

When we generate the gir-file we need to refer to the source files
relative to the srcdir to support out-of-source-tree builds.

15 years agoAdd BABL_IS_BEING_COMPILED #define support
Martin Nordholts [Mon, 27 Dec 2010 20:34:00 +0000 (21:34 +0100)]
Add BABL_IS_BEING_COMPILED #define support

Sometimes it is ok that babl includes are included directly and not
through babl.h, like when we generate GObject introspection files.

The important thing is just that users of the babl API don't begin to
include headers we don't guarantee to always exist, and
BABL_IS_BEING_COMPILED doesn't obstruct this goal.

15 years agoAdd Babl-$(BABL_API_VERSION).gir dependencies
Martin Nordholts [Mon, 27 Dec 2010 20:30:58 +0000 (21:30 +0100)]
Add Babl-$(BABL_API_VERSION).gir dependencies

Add Babl-$(BABL_API_VERSION).gir dependencies for proper
auto-recompilation.

15 years agodisable DEBUG_MEM
Øyvind Kolås [Sat, 18 Dec 2010 00:12:01 +0000 (00:12 +0000)]
disable DEBUG_MEM

This option provides a hit in multithreaded use, and should only be enabled
when debugging babl memory allocation internals.

15 years agobuild/buildbot: Supress AM_PROG_LIBTOOL warning with autoconf 2.68
Martin Nordholts [Wed, 29 Sep 2010 20:19:46 +0000 (22:19 +0200)]
build/buildbot: Supress AM_PROG_LIBTOOL warning with autoconf 2.68

15 years agoconfigure.ac: Use AC_LANG_PROGRAM to generate test-program
Martin Nordholts [Wed, 29 Sep 2010 19:55:30 +0000 (21:55 +0200)]
configure.ac: Use AC_LANG_PROGRAM to generate test-program

Use AC_LANG_PROGRAM to generate test-program for AC_COMPILE_IFELSE, so
we don't get

  warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body

in autoconf 2.68.

Second try, we must quote macro arguments...

15 years agoconfigure.ac: Use AC_LANG_PROGRAM to generate test-program
Martin Nordholts [Wed, 29 Sep 2010 19:55:30 +0000 (21:55 +0200)]
configure.ac: Use AC_LANG_PROGRAM to generate test-program

Use AC_LANG_PROGRAM to generate test-program for AC_COMPILE_IFELSE, so
we don't get

  warning: AC_LANG_CONFTEST: no AC_LANG_SOURCE call detected in body

in autoconf 2.68.

15 years agoadded Rubert Weber to AUTHORS
Øyvind Kolås [Sun, 12 Sep 2010 16:23:52 +0000 (17:23 +0100)]
added Rubert Weber to AUTHORS

15 years agocreate double format for every model
Rupert Weber [Sat, 11 Sep 2010 19:17:34 +0000 (21:17 +0200)]
create double format for every model

Changes babl_model_new() to create a respective double format
for every new registered model.

That way applications and extensions can rely on the double
format to always exist.